package com.loadmore.basic;

import android.content.Context;
import android.view.View;
import android.view.ViewGroup;

import com.loadmore.baselibrary.adapter.RVBaseAdapter;
import com.loadmore.baselibrary.adapter.RVBaseHolder;

/**
 * @author sunleilei
 * @date 2017/5/14
 */

public class MainListAdapter extends RVBaseAdapter {

    public MainListAdapter(Context context) {
        super(context);
    }

    @Override
    public RVBaseHolder createHolder(ViewGroup parent, int viewType) {
        View view = inflater.inflate(R.layout.main_list_item,parent,false);
        return new RVBaseHolder(view);
    }

    @Override
    public void bindHolder(RVBaseHolder holder, int position) {
        String string = (String) items.get(position);
        holder.setText(R.id.title,string);
    }
}
